import {
    post,
    get,
    put,
    dalete,
    postJosn,
    putone,
    patch,
    daleteJson
  } from '../utils/request';
  
  //分页查询商品活动列表
  export function queryGoodsActivityList(data) {
    return post('/api/promotion-service/v1/promotionTastingWine/qryRedPacketList', data);
    //return post('http://127.0.0.1:18080/api/promotion-service/v1/promotionBuyFree/qryBuyFreeActiviteList', data);
  }
  
  //发布撤回删除活动
  export function updateGoodsActivityStatus(data) {
    return post('/api/promotion-service/v1/promotionTastingWine/modifyRedPacketStatus?uuid='+data.uuid+'&status='+data.status);
    //return post('http://127.0.0.1:18080/api/promotion-service/v1/promotionBuyFree/editBuyFreeActiviteInfo?uuid='+data.uuid+'&status='+data.status);
  }
  
  //删除活动
  export function deleteGoodsActivity(data) {
  }
  
  //获取活动详细
  export function queryGiftActivityDetail(data){
    return post('/api/promotion-service/v1/promotionBuyFree/qryBuyFreeActiviteInfo?uuid='+data.uuid);
    //return post('http://127.0.0.1:18080/api/promotion-service/v1/promotionBuyFree/qryBuyFreeActiviteInfo?uuid='+data.uuid);
  }
  
  //活动商品分类列表
  export function qryGoodsTypeList(data) {
    return post('/api/goods-service/v1/foreignGoods/qryGoodsTypeList', data)
    //return post('http://127.0.0.1:18080/api/goods-service/v1/foreignGoods/qryGoodsTypeList', data);
  }
  
  //挑选商品
  export function queryChooseGoodsList(data) {
    return post('/api/goods-service/v1/foreignGoods/qryBuyFreeGoodsList', data)
    //return post('http://127.0.0.1:18080/api/goods-service/v1/foreignGoods/qryBuyFreeGoodsList', data);
  }
  
  //挑选赠品
  export function queryChooseGiftsList(data) {
    return post('/api/promotion-service/v1/promotionTastingWine/qryTastingWine', data);
    //return post('http://127.0.0.1:18080/api/promotion-service/v1/promotionBuyFree/qryGiftBank', data);
  }
  
  //保存活动（全部数据）
  export function saveGiftActivityWithGoods(data) {
    return post('/api/promotion-service/v1/promotionTastingWine/modifyRedPacket', data);
    //return post('http://127.0.0.1:18080/api/promotion-service/v1/promotionBuyFree/editBuyFreeActivite', data);
  }

   
  //保存活动（全部数据）
  export function qryShareActiviteInfo(data) {
    return get('/api/promotion-service/v1/promotionTastingWine/qryRedPacketInfo', data);
    //return post('http://127.0.0.1:18080/api/promotion-service/v1/promotionBuyFree/editBuyFreeActivite', data);
  }
  
  